
{"id":8271,"date":"2013-03-20T18:16:06","date_gmt":"2013-03-20T18:16:06","guid":{"rendered":"http:\/\/www.beautifulwork.org\/?p=8271"},"modified":"2013-03-20T18:16:06","modified_gmt":"2013-03-20T18:16:06","slug":"perl-testing-for-gcc-compiler-option-related","status":"publish","type":"post","link":"https:\/\/www.trueangle.org\/index.php\/2013\/03\/20\/perl-testing-for-gcc-compiler-option-related\/","title":{"rendered":"Perl TESTING for gcc compiler option related"},"content":{"rendered":"<h4><u>commandline session<\/u><\/h4>\n<pre>\n$cat testgcc.pl\n#!\/usr\/bin\/perl -w\n\nuse Test::More tests =&gt; 2 ;\n\nmy $result;\n\nsystem \"gcc unsigned.c\";\n$result = `.\/a.out`;\n#print $result;\nok ($result lt 0);\n\n\nsystem \"gcc -funsigned-char unsigned.c\";\n$result = `.\/a.out`;\n#print $result;\nok ($result gt 0);\n\n$cat unsigned.c\n#include\n\nint main(void)\n{\n  char c = -10;\n  printf(\"%d\",c);\n  return 0;\n}\n$perl testgcc.pl\n1..2\nok 1\nok 2\n$\n\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>commandline session $cat testgcc.pl #!\/usr\/bin\/perl -w use Test::More tests =&gt; 2 ; my $result; system &#8220;gcc unsigned.c&#8221;; $result = `.\/a.out`; #print $result; ok ($result lt 0); system &#8220;gcc -funsigned-char unsigned.c&#8221;; $result = `.\/a.out`; #print $result; ok ($result gt 0); $cat unsigned.c #include int main(void) { char c = -10; printf(&#8220;%d&#8221;,c); return 0; } $perl testgcc.pl &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.trueangle.org\/index.php\/2013\/03\/20\/perl-testing-for-gcc-compiler-option-related\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Perl TESTING for gcc compiler option related&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/posts\/8271"}],"collection":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/comments?post=8271"}],"version-history":[{"count":0,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/posts\/8271\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/media?parent=8271"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/categories?post=8271"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.trueangle.org\/index.php\/wp-json\/wp\/v2\/tags?post=8271"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}