mirror of
https://github.com/lcn2/calc.git
synced 2025-08-16 01:03:29 +03:00
Add config("complex_space") to control spaces around + or - in complex values
Added config("fraction_space", boolean) to help/config, along with a few few minor text improvements. Updated cal/regress to test config("tilde_space"). Added config("complex_space", boolean). The "complex_space" controls whether or not a space (' ') is printed before and after the + or - in complex values. By default, config("complex_space") is false. For example, with the default, config("complex_space", 0): ; asin(2) 1.57079632679489661923-1.31695789692481670863i With config("complex_space", 1): ; asin(2) 1.57079632679489661923 - 1.31695789692481670863i NOTE: Use of config("complex_space", 1) can break printing and scanning of fractional values via "%r". NOTE: Use of config("complex_space", 1) can break printing and scanning of complex values via "%c". Added config("complex_space", boolean) to help/config, along with a few few minor text improvements. Updated cal/regress to test config("complex_space").
This commit is contained in:
@@ -547,8 +547,10 @@ define test_config()
|
||||
'563: config("tilde_space") == 0');
|
||||
vrfy(config("fraction_space") == 0,
|
||||
'564: config("fraction_space") == 0');
|
||||
vrfy(config("complex_space") == 0,
|
||||
'565: config("complex_space") == 0');
|
||||
|
||||
print '565: Ending test_config';
|
||||
print '566: Ending test_config';
|
||||
}
|
||||
print '010: parsed test_config()';
|
||||
|
||||
|
Reference in New Issue
Block a user