{"id":141,"date":"2007-11-14T00:12:40","date_gmt":"2007-11-13T15:12:40","guid":{"rendered":"http:\/\/59.106.179.184\/ja\/blog\/?p=141"},"modified":"2022-08-28T13:36:29","modified_gmt":"2022-08-28T04:36:29","slug":"c%e3%81%a7%e3%83%a1%e3%83%a2%e3%83%aa%e3%83%aa%e3%83%bc%e3%82%af%e3%82%92%e6%a4%9c%e5%87%ba%e3%81%99%e3%82%8b%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/blog.tmyymmt.net\/ja\/?p=141","title":{"rendered":"C++\u3067\u30e1\u30e2\u30ea\u30ea\u30fc\u30af\u3092\u691c\u51fa\u3059\u308b\u65b9\u6cd5"},"content":{"rendered":"<p>C++@Linux\u306a\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u30e1\u30e2\u30ea\u30ea\u30fc\u30af\u304c\u767a\u751f\u3002<br \/>\n<a href=\"http:\/\/www.google.co.jp\/search?q=MemProf\">MemProf<\/a>\u3001<a href=\"http:\/\/www.google.co.jp\/search?q=mtrace\">mtrace<\/a>\u3001<a href=\"http:\/\/www.google.co.jp\/search?q=ccmalloc\">ccmalloc<\/a>\u3001<a href=\"http:\/\/www.google.co.jp\/search?q=mpatrol\">mpatrol<\/a>\u3001<a href=\"http:\/\/www.google.co.jp\/search?q=dmalloc\">dmalloc<\/a>\u3092\u30c1\u30a7\u30c3\u30af\u3057\u305f\u304c\u3001\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u74b0\u5883\u3067\u4f7f\u3048\u308b\u306e\u306fmtrace\u3060\u3051\u3060\u3063\u305f\u3002<br \/>\n\u3057\u304b\u3057new\/delete\u306e\u5834\u5408\u306f\u30ea\u30fc\u30af\u306e\u5b58\u5728\u306f\u78ba\u8a8d\u3067\u304d\u308b\u304c\u30bd\u30fc\u30b9\u30d5\u30a1\u30a4\u30eb\u540d\u3068\u884c\u756a\u53f7\u307e\u3067\u306f\u51fa\u529b\u3055\u308c\u305a(malloc\/free\u306e\u5834\u5408\u306f\u884c\u756a\u53f7\u307e\u3067\u51fa\u529b\u3055\u308c\u308b)\u3002dmalloc\u306fc++\u306enew\/delete\u3067\u3082\u5229\u7528\u53ef\u80fd\u3089\u3057\u3044\u306e\u3060\u304c\u3001\u3044\u3056\u5bfe\u8c61\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u3068\u30ea\u30f3\u30af\u3057\u3088\u3046\u3068\u3059\u308b\u3068\u30ea\u30f3\u30af\u30a8\u30e9\u30fc\u3067\u4f7f\u3048\u306a\u3044\u3002<br \/>\n\u95a2\u9023\u60c5\u5831\u3092\u8abf\u3079\u305f\u3042\u3052\u304f\u3001\u4ed5\u65b9\u306a\u3044\u306e\u3067\u81ea\u5206\u3067\u30b3\u30fc\u30c9\u3092\u66f8\u3044\u3066\u307f\u305f\u3002<\/p>\n<ul>\n<li><a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/DetectMemoryLeaks.h\">DetectMemoryLeaks.h<\/a><\/li>\n<li><a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/DetectMemoryLeaks.cpp\">DetectMemoryLeaks.cpp<\/a><\/li>\n<li><a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/MemoryLeaksSample.cpp\">MemoryLeaksSample.cpp<\/a><\/li>\n<\/ul>\n<p>\u5185\u5bb9\u3068\u3057\u3066\u306f\u3001new\u3001new[]\u3001delete\u3001delete[]\u3001\u3092\u30aa\u30fc\u30d0\u30fc\u30e9\u30a4\u30c9\u307e\u305f\u306f\u30aa\u30fc\u30d0\u30fc\u30ed\u30fc\u30c9\u3057\u3066\u3001\u30e1\u30e2\u30ea\u306e\u78ba\u4fdd\u3068\u89e3\u653e\u306e\u30bf\u30a4\u30df\u30f3\u30b0\u3067\u5bfe\u5fdc\u3092\u30c1\u30a7\u30c3\u30af\u3002\u30e1\u30e2\u30ea\u78ba\u4fdd\u3057\u305f\u306e\u306b\u89e3\u653e\u3055\u308c\u3066\u3044\u306a\u3044\u5834\u5408\u306f\u3001\u305d\u306e\u30e1\u30e2\u30ea\u3092\u78ba\u4fdd\u3057\u305f\u30bd\u30fc\u30b9\u4e0a\u306e\u30d5\u30a1\u30a4\u30eb\u540d\u3068\u884c\u756a\u53f7\u3092\u8868\u793a\u3059\u308b\u3002<br \/>\n1. <a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/DetectMemoryLeaks.h\">DetectMemoryLeaks.h<\/a> \u3068 <a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/DetectMemoryLeaks.cpp\">DetectMemoryLeaks.cpp<\/a> \u3092\u30b3\u30d4\u30fc\u3002<br \/>\n2. DetectMemoryLeaks.cpp\u3092\u30b3\u30f3\u30d1\u30a4\u30eb\u5bfe\u8c61\u306b\u8ffd\u52a0\u3002<br \/>\n3. \u6700\u521d\u306b\u30b3\u30f3\u30d1\u30a4\u30eb\u3055\u308c\u308b\u30bd\u30fc\u30b9\u306b\u6b21\u306e2\u884c\u3092\u8ffd\u52a0\u3002<br \/>\n&nbsp;&nbsp;&nbsp; #include &#8220;MemoryLeakChecker.h&#8221;<br \/>\n&nbsp;&nbsp;&nbsp; #define new new(__FILE__, __LINE__ )<br \/>\n4. \u30e1\u30e2\u30ea\u30fc\u30ea\u30fc\u30af\u3092\u30c1\u30a7\u30c3\u30af\u3057\u305f\u3044\u7bc4\u56f2\u306e\u958b\u59cb\u4f4d\u7f6e\u306b\u6b21\u306e1\u884c\u3092\u8ffd\u52a0\u3002<br \/>\n&nbsp;&nbsp;&nbsp; memoryLeakCheckerCheckStart(std::cout);<br \/>\n5. \u30e1\u30e2\u30ea\u30fc\u30ea\u30fc\u30af\u3092\u30c1\u30a7\u30c3\u30af\u3057\u305f\u3044\u7bc4\u56f2\u306e\u7d42\u4e86\u4f4d\u7f6e\u306b\u6b21\u306e1\u884c\u3092\u8ffd\u52a0\u3002<br \/>\n&nbsp;&nbsp;&nbsp; memoryLeakCheckerCheckEnd(std::cout);<br \/>\n6. \u5bfe\u8c61\u3092\u30b3\u30f3\u30d1\u30a4\u30eb\u3057\u3066\u3001\u5b9f\u884c\u3059\u308c\u3070OK\u3002<br \/>\n\u4f7f\u3044\u65b9\u306e\u30b5\u30f3\u30d7\u30eb\u306f\u3053\u3061\u3089(<a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/MemoryLeaksSample.cpp\">MemoryLeaksSample.cpp<\/a>)\u3002<br \/>\n\u6ce8\u610f\uff1a\u30de\u30eb\u30c1\u30b9\u30ec\u30c3\u30c9\u306f\u8003\u616e\u3057\u3066\u3044\u307e\u305b\u3093\u3002detectMemoryLeaksStart\/End\u547c\u3073\u51fa\u3057\u306e\u5165\u308c\u5b50\u306f\u8003\u616e\u3057\u3066\u3044\u307e\u305b\u3093\u3002<\/p>\n<p><a href=\"http:\/\/tmyymmt.net\/cpp\/memoryleaks\/DetectMemoryLeaks.cpp\">DetectMemoryLeaks.cpp<\/a> \u306e\u5185\u5bb9\u3002<\/p>\n<blockquote><p><span style=\"font-size: 0.8em;\">std::map detectMemoryLeaksMemoryMap;<br \/>\nbool detectMemoryLeaksFlag = false;<\/span><\/p>\n<p><span style=\"font-size: 0.8em;\">void *<br \/>\noperator new(std::size_t size, char * pszFileName, int nLineNum)<br \/>\nthrow (std::bad_alloc)<br \/>\n{<br \/>\n&nbsp;&nbsp;&nbsp; void * address = malloc(size);<br \/>\n&nbsp;&nbsp;&nbsp; if(address == 0)<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; throw std::bad_alloc();<br \/>\n&nbsp;&nbsp;&nbsp;<br \/>\n&nbsp;&nbsp;&nbsp; if(detectMemoryLeaksFlag){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \/\/ std::cout &lt;&lt; &#8220;new: &#8221; &lt;&lt; pszFileName &lt;&lt; &#8220;:&#8221; &lt;&lt; nLineNum &lt;&lt; &#8221; size=&#8221; &lt;&lt; size &lt;&lt; &#8221; address=&#8221; &lt;&lt; address &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::ostringstream oss;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; oss &lt;&lt; pszFileName &lt;&lt; &#8220;:&#8221; &lt;&lt; nLineNum &lt;&lt; &#8221; size=&#8221; &lt;&lt; size&nbsp; &lt;&lt; &#8221; address=&#8221; &lt;&lt; address;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; detectMemoryLeaksMemoryMap.insert( std::pair((std::size_t)address, oss.str()) );<br \/>\n&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; return address;<br \/>\n}<\/span><\/p>\n<p><span style=\"font-size: 0.8em;\">void *<br \/>\noperator new[](std::size_t size, char * pszFileName, int nLineNum)<br \/>\nthrow (std::bad_alloc)<br \/>\n{<br \/>\n&nbsp;&nbsp;&nbsp; void * address = malloc(size);<br \/>\n&nbsp;&nbsp;&nbsp; if(address == 0)<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; throw std::bad_alloc();<br \/>\n&nbsp;&nbsp;&nbsp;<br \/>\n&nbsp;&nbsp;&nbsp; if(detectMemoryLeaksFlag){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \/\/ std::cout &lt;&lt; &#8220;new[]: &#8221; &lt;&lt; pszFileName &lt;&lt; &#8220;:&#8221; &lt;&lt; nLineNum &lt;&lt; &#8221; size=&#8221; &lt;&lt; size &lt;&lt; &#8221; address=&#8221; &lt;&lt; address &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::ostringstream oss;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; oss &lt;&lt; pszFileName &lt;&lt; &#8220;:&#8221; &lt;&lt; nLineNum &lt;&lt; &#8221; size=&#8221; &lt;&lt; size&nbsp; &lt;&lt; &#8221; address=&#8221; &lt;&lt; address;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; detectMemoryLeaksMemoryMap.insert( std::pair((std::size_t)address, oss.str()) );<br \/>\n&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; return address;<br \/>\n}<\/span><\/p>\n<p><span style=\"font-size: 0.8em;\">void<br \/>\noperator delete(void * address)<br \/>\n{<br \/>\n&nbsp;&nbsp;&nbsp; if(address == 0) \/\/ Depends on environment.<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return;<br \/>\n&nbsp;&nbsp;&nbsp;<br \/>\n&nbsp;&nbsp;&nbsp; if(detectMemoryLeaksFlag){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \/\/ std::cout &lt;&lt; &#8220;delete: &#8221; &lt;&lt; &#8221; address=&#8221; &lt;&lt; address &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::map::iterator it = detectMemoryLeaksMemoryMap.begin();<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::map::iterator itEnd = detectMemoryLeaksMemoryMap.end();<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::size_t checkAddress = (std::size_t)address;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for(; it!=itEnd; it++){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(it-&gt;first == checkAddress){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; detectMemoryLeaksMemoryMap.erase(it);<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; break;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; free(address);<br \/>\n}<\/span><\/p>\n<p><span style=\"font-size: 0.8em;\">void<br \/>\noperator delete[](void * address)<br \/>\n{<br \/>\n&nbsp;&nbsp;&nbsp; if(address == 0) \/\/ Depends on environment.<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return;<br \/>\n&nbsp;&nbsp;&nbsp;<br \/>\n&nbsp;&nbsp;&nbsp; if(detectMemoryLeaksFlag){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \/\/ std::cout &lt;&lt; &#8220;delete[]: &#8221; &lt;&lt; &#8221; address=&#8221; &lt;&lt; address &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::map::iterator it = detectMemoryLeaksMemoryMap.begin();<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::map::iterator itEnd = detectMemoryLeaksMemoryMap.end();<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::size_t checkAddress = (std::size_t)address;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for(; it!=itEnd; it++){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(it-&gt;first == checkAddress){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; detectMemoryLeaksMemoryMap.erase(it);<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; break;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; fr<br \/>\nee(address);<br \/>\n}<\/span><\/p>\n<p><span style=\"font-size: 0.8em;\">void<br \/>\ndetectMemoryLeaksStart(std::ostream&amp; ros)<br \/>\n{<br \/>\n&nbsp;&nbsp;&nbsp; ros &lt;&lt; &#8220;[detect memory leaks] start&#8221; &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp; detectMemoryLeaksFlag = true;<br \/>\n}<\/span><\/p>\n<p><span style=\"font-size: 0.8em;\">void<br \/>\ndetectMemoryLeaksEnd(std::ostream&amp; ros)<br \/>\n{<br \/>\n&nbsp;&nbsp;&nbsp; ros &lt;&lt; &#8220;[detect memory leaks] end&#8221; &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp; if(detectMemoryLeaksMemoryMap.size() &gt; 0){<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ros &lt;&lt; &#8220;memory leaks &#8230;&#8221; &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::map::iterator it = detectMemoryLeaksMemoryMap.begin();<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::map::iterator itEnd = detectMemoryLeaksMemoryMap.end();<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for(; it!=itEnd; it++)<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ros &lt;&lt; &#8221;&nbsp; &#8221; &lt;&lt; it-&gt;second &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp; }else{<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ros &lt;&lt; &#8220;memory leak is nothing.&#8221; &lt;&lt; std::endl;<br \/>\n&nbsp;&nbsp;&nbsp; }<br \/>\n&nbsp;&nbsp;&nbsp; detectMemoryLeaksFlag = false;<br \/>\n&nbsp;&nbsp;&nbsp; detectMemoryLeaksMemoryMap.clear();<br \/>\n}<\/span><\/p><\/blockquote>\n<p>\u306b\u3057\u3066\u3082\u3001\u4eca\u6642C++\u3092\u4f7f\u3046\u306e\u306f\u6b63\u76f4\u3069\u3046\u304b\u3068\u3002\u3088\u307b\u3069\u30e1\u30e2\u30ea\u3084CPU\u304c\u9650\u3089\u308c\u305f\u6761\u4ef6\u3067\u306f\u4ed5\u65b9\u306a\u3044\u304b\u3082\u3057\u308c\u306a\u3044\u304c\u3002\u30c1\u30fc\u30e0\u3067\u30bd\u30d5\u30c8\u3092\u4f5c\u308b\u969b\u306bC++\u3092\u4f7f\u3046\u3068\u7d30\u304b\u3044\u3053\u3068\u307e\u3067\u4e8b\u524d\u306b\u6c7a\u3081\u306a\u3044\u3068\u3050\u3061\u3083\u3050\u3061\u3083\u306b\u306a\u308b\u3057\u3002\u5404\u7a2e\u30e9\u30a4\u30d6\u30e9\u30ea\u3082\u69cb\u6210\u3084\u30cd\u30fc\u30df\u30f3\u30b0\u306b\u7d71\u4e00\u611f\u7121\u3044\u3057\u3002\u30cf\u30fc\u30c9\u306e\u6027\u80fd\u5411\u4e0a\u901f\u5ea6\u3001\u30e1\u30f3\u30d0\u30fc\u306e\u6559\u80b2\u3001\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u30eb\u30fc\u30eb\u306e\u7b56\u5b9a\u3068\u53b3\u5b88\u3001\u30c7\u30d0\u30c3\u30b0\u3001\u53ef\u8aad\u6027\u3092\u8003\u616e\u3057\u3066\u3001\u30bd\u30d5\u30c8\u306e\u30b5\u30a4\u30af\u30eb\u3092\u30c8\u30fc\u30bf\u30eb\u7684\u8003\u3048\u308b\u3068\u52b9\u7387\u304c\u60aa\u3044\u3002GC\u306e\u6700\u5927\u6642\u9593\u304c\u4fdd\u969c\u3055\u308c\u305fJavaVM\u4f7f\u3063\u305f\u65b9\u304c\u30c8\u30fc\u30bf\u30eb\u30b3\u30b9\u30c8\u3082\u4e0b\u304c\u308b\u3057\u5b89\u5168\u3060\u3057\u52b9\u7387\u304c\u826f\u3044\u3068\u601d\u3046\u3002(GC\u9818\u57df\u3092\u9650\u5b9a\u3059\u308c\u3070\u6642\u9593\u4fdd\u969c\u306f\u78ba\u4fdd\u3067\u304d\u308b\u3060\u308d\u3046\u3002)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>C++@Linux\u306a\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u30e1\u30e2\u30ea\u30ea\u30fc\u30af\u304c\u767a\u751f\u3002 MemProf\u3001mtra &hellip; <a href=\"https:\/\/blog.tmyymmt.net\/ja\/?p=141\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[80,85,19,83,81,84,86,201,82],"class_list":["post-141","post","type-post","status-publish","format-standard","hentry","category-1","tag-c","tag-memory-leak","tag-programming","tag-83","tag-81","tag-84","tag-86","tag-201","tag-82"],"_links":{"self":[{"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=\/wp\/v2\/posts\/141","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=141"}],"version-history":[{"count":4,"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=\/wp\/v2\/posts\/141\/revisions"}],"predecessor-version":[{"id":854,"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=\/wp\/v2\/posts\/141\/revisions\/854"}],"wp:attachment":[{"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=141"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=141"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.tmyymmt.net\/ja\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=141"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}