Changeset 36 in dev for BasicCompiler32/Compile_Set_Var.cpp
- Timestamp:
- Jan 20, 2007, 4:55:26 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
BasicCompiler32/Compile_Set_Var.cpp
r28 r36 874 874 } 875 875 } 876 void SetBooleanVariable(int type,RELATIVE_VAR *pRelative){ 877 if(type==DEF_DOUBLE){ 878 // TODO: 実装 879 } 880 else if(type==DEF_SINGLE){ 881 // TODO: 実装 882 } 883 else if(type==DEF_INT64||type==DEF_QWORD){ 884 // TODO: 実装 885 886 //pop eax 887 op_pop(REG_EAX); 888 889 //cmp eax,0 890 op_cmp_value(GetTypeSize(type,-1),REG_EAX,0); 891 892 //setne al 893 op_setne( REG_EAX ); 894 895 //pop ecx 896 op_pop(REG_ECX); 897 898 //cmp ecx,0 899 op_cmp_value(GetTypeSize(type,-1),REG_ECX,0); 900 901 //setne cl 902 op_setne( REG_ECX ); 903 904 //or al,cl 905 op_or_RR( sizeof( _int8 ), REG_EAX, REG_ECX ); 906 } 907 else{ 908 if(!IsWholeNumberType(type)){ 909 //不正な型の場合 910 SetError(9,NULL,cp); 911 return; 912 } 913 914 //pop eax 915 op_pop(REG_EAX); 916 } 917 918 //cmp eax,0 919 op_cmp_value(GetTypeSize(type,-1),REG_EAX,0); 920 921 //setne al 922 op_setne( REG_EAX ); 923 924 //push eax 925 op_push(REG_EAX); 926 927 Set8Variable(DEF_BYTE,pRelative->dwKind,pRelative->offset,pRelative->bOffsetOffset); 928 }
Note:
See TracChangeset
for help on using the changeset viewer.