#include "longint.hsp" #module m_one_plus_float member_LI_value,member_LI_decimal,member_decimal_places,member_after_mul,member_after_DIV #modinit if _keta_flag==0{ _10keta=LongInt(100000) _10keta*=100000 _keta_flag=1 } member_LI_value=LongInt(0) member_LI_decimal=LongInt(0) member_decimal_places=10 member_after_mul=1 member_after_div=1 // decimal:小数 // place:桁 return #modfunc local dump logmes "LI_value:"+str(member_LI_value) logmes "LI_decimal:"+str(member_LI_decimal) logmes "桁(小数):"+str(member_decimal_places) ; logmes "_10keta:"+str(_10keta) logmes "after_mul:"+str(member_after_mul) logmes "after_div:"+str(member_after_div) return #modfunc local cut_by_10keta member_LI_decimal\=_10keta return #modfunc local cut_by_4keta member_LI_decimal\=10000 return #modfunc local set_values var _p_value,var _p_decimal,int _p_places member_LI_value=_p_value member_LI_decimal=_p_decimal member_decimal_places=_p_places return #modfunc local set_after_mul var _p_after_mul member_after_mul=_p_after_mul return #modfunc local set_after_div var _p_after_div member_after_div=_p_after_div return #global #module m_plus_float arg_1st_plus_float,obj_operand,arg_2nd_plus_float #modinit newmod _1st_mf_obj,m_one_plus_float obj_operand="" // operand:演算子 newmod _2nd_mf_obj,m_one_plus_float return #modfunc local dump logmes "1st arg" dump@m_one_plus_float _1st_mf_obj logmes "演算:"+obj_operand logmes "2nd arg" dump@m_one_plus_float _2nd_mf_obj return #modfunc local set_operand str p_operand obj_operand=p_operand return #modfunc local set_arg_1st_values var p_value,var p_decimal,int p_places set_values@m_one_plus_float _1st_mf_obj,p_value,p_decimal,p_places return #modfunc local set_arg_2nd_values var p_value,var p_decimal,int p_places set_values@m_one_plus_float _2nd_mf_obj,p_value,p_decimal,p_places return #modfunc local cut_by_10keta_1st cut_by_10keta@m_one_plus_float _1st_mf_obj return #modfunc local cut_by_4keta_1st cut_by_4keta@m_one_plus_float _1st_mf_obj return #modfunc local cut_by_10keta_2nd cut_by_10keta@m_one_plus_float _2nd_mf_obj return #modfunc local cut_by_4keta_2nd cut_by_4keta@m_one_plus_float _2nd_mf_obj return #global newmod tmp_LI,m_plus_float tmp_l1=LongInt(12345678) tmp_l1*=100000000 tmp_l1+=12345678 tmp_l2=LongInt(56781234) tmp_l2*=100000000 tmp_l2+=56781234 tmp_l3=10 set_arg_1st_values@m_plus_float tmp_LI,tmp_l1,tmp_l2,tmp_l3 set_operand@m_plus_float tmp_LI,"SUB" tmp_arg_l1=LongInt("8765432187654321") tmp_arg_l2=LongInt("4321876543218765") tmp_arg_l3=10 set_arg_2nd_values@m_plus_float tmp_LI,tmp_arg_l1,tmp_arg_l2,tmp_arg_l3 dump@m_plus_float tmp_LI cut_by_10keta_1st@m_plus_float tmp_LI cut_by_10keta_2nd@m_plus_float tmp_LI dump@m_plus_float tmp_LI cut_by_4keta_1st@m_plus_float tmp_LI cut_by_4keta_2nd@m_plus_float tmp_LI dump@m_plus_float tmp_LI
17/03/29:ver 0.01