unaffected
Since the result is returned to the program being analyzed, and the result
changes the behavior of the program being analyzed, therefore the result
of the analysis is different. If the result is NOT returned to the program
being analyzed, then the behavior of the program is NOT changed, and
the result of the analysis is conclusive. It really very simple.
The above paragraph doesn't make sense to me. Do you think that I'm trying
to modify your analysis program? I'm not. I'm producing source code (just
text, not an executable) for you to pass as input to your program. The
input source code resembles the source for your program because it uses the
same logic that your analysis program uses. That's the case when the
program fails: when the input uses a specially-crafted version of the very
program that is performing the analysis. It fails because
WillHaltWithReturnValue() fails, plain and simple.
This will hopefully be my last post in this thread, because tom_usenet has
talked some sense in to me. I'm not going to argue with you any more. I
just wanted to leave a final message with instructions on how you may come
to realize that your function, WillHalt(), is incorrect for the same input
that the other function, WillHaltWithReturnValue() is incorrect. To be
honest, I'm feeling sorry for you because everyone else seems to "get it"
and you don't. If these instructions help you to see the truth, then please
post a response saying so, because it will at least make me feel as though
my time has not been wasted.
Clear your mind of compilers, interpreters, executeable files, memory,
binary, and other things that we use to translate an abstract flow into a an
implementation of that flow, because they are irrelevant. If you ever get
an idea to you could use any of them to differentiate between the two
functions, ignore it. The halting problem works on an abstract machine, and
because all implementations of the machine are subject to the same rules for
implementing the logical flow, anything proven about this primitive abstract
machine applies to any implementation. Consider a fictional machine that
may not be anything like what you are using today. Focus on the Turing
machine.
Avoid using the word "result" to mean something that is a property of the
implementation. For example, do not say that the result is a bit pattern,
or the result is some file, or the result is in the stack. If you do that,
then you are not thinking about the abstract machine. You may accidentally
think that two results are not the same because they do not have the same
representation in the implementation. The representation of a result in the
implementation is irrelevant when considering its correctness. A integer
result of zero that indicates false, a file containing the string "false",
and someone's whispering of "false" in your ear are all equivalent results
because they indicate the same thing. That is, they are the same answer
with a different, irrelevant, representation. As an analogy, if I ask you
to give me the names of all 50 states, and you give me a piece of paper with
them written down, you are just as correct when you say them aloud.
Keep in mind that the UNKNOWN should never be reached for valid input. In
that case, the result must be TRUE or FALSE. If the input is valid and the
program returns UNKNOWN, then it has failed the test. If UNKNOWN were to be
an acceptable answer for valid input, then a program that only consisted of
"return UNKNOWN;" would be a solution. I kept the UNKNOWN value in the
source because I thought it might be used for invalid input and I wanted it
to be as close to the original function as possible. I probably should have
removed it to avoid confusion.
Lastly, avoid focusing on one particular sentence in my posts. I usually
break my posts up into paragraphs for a good reason, so try to understand
the entire paragraph when you apply my posts to your halting problem
"solution."
Now, if you look at the two functions provided and still argue that the
result when display on the screen can be different than the result provided
in the return value, then you must be appealing to an irrelevant
implementation detail that does not affect the result. Once you understand
why both functions, given any input, always produce the same result, you
will understand that they are both wrong when passed the "difficult input"
that looks something like the code I gave you. Remember: a program that,
for every input, always produces the same result as a program that is
incorrect on a particular input will also be incorrect on the same input,
even if the executing code is different. If you're still having problems,
see the post where I provided source code, go to the link I provided, and
make sure you fully understand it. Now consider the case when my source is
passed to your function.
If you think the above points are debateable and wish to respond to them, I
will read your response and consider your counterpoints, but I will probably
not respond back.