Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"TODO: Make this work" #77

Open
Zachary-Kramer opened this issue Oct 5, 2017 · 3 comments
Open

"TODO: Make this work" #77

Zachary-Kramer opened this issue Oct 5, 2017 · 3 comments

Comments

@Zachary-Kramer
Copy link
Contributor

I was modifying the output for CO2 and came across the following comment on line 773 of SW_Output.c. Does any one know what needed to be done here?

PROTECT(sep = GET_SLOT(OUT, install("outputSeparator")));
_Sep = '\t';/*TODO Make this work.*/
PROTECT(useTimeStep = GET_SLOT(OUT, install("useTimeStep")));```
@dschlaep
Copy link
Member

dschlaep commented Oct 6, 2017

Based on blame, this comment was added with commit 477acff by Ryan.

I guess this comment was meant to suggest that the code should be improved so that it allows _Sep take the value of the input sep instead of it being fixed at \t?

@Zachary-Kramer
Copy link
Contributor Author

Thanks. It seems that _Sep is defaulted at \t but can be changed to a space or sumtype based on OUTSEP:

if (Str_CompareI(keyname, "OUTSEP") == 0)
				{
					switch ((int) *sumtype)
					{
					case 't':
						_Sep = '\t';
						break;
					case 's':
						_Sep = ' ';
						break;
					default:
						_Sep = *sumtype;
					}
					continue;
				}

It seems that one just can't set it through rSOILWAT2's onSet_SW_OUT (maybe even calling onSet overwrites the file value above?).

Should a low priority issue be created?

@dschlaep
Copy link
Member

dschlaep commented Oct 6, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants