前段時間,我問一個問題:How do I redefine built in Perl functions? 而且答案對我很好。我有一個壓縮Perl的「開放」功能的軟件包,使我能夠登錄文件訪問。 現在我來介紹一個打破原始代碼功能的案例。 use strict;
use warnings;
use Data::Dumper;
sub myopen (*;@) {
my $p;
我有一個使用一些代碼: __sync_bool_compare_and_swap
它編譯在Linux的罰款。 但是,當我嘗試編譯它的MacOSX上g ++中,我得到: error: ‘__sync_bool_compare_and_swap’ was not declared in this scope
我該如何解決這個問題? (這是Mac OSX 10.5.8,所以它是英特爾..,應該有