![]() This blog covers mainly the Matlab core product and closely-related toolboxes. This topic is very important to MathWorks, as evidenced by a dedicated documentation section, newsletter articles ( 1, 2), webinars ( 1, 2, 3, 4) and multiple blog posts on improving simulation performance using the Simulink product. ![]() I hope that nobody will introduce another category-code or whatever for inline-comments: This would require (La)TeX to care about matching inline-comment-characters and the like and this would provide another area where things could get messy.A few days ago I happened to speak with a colleague about Simulink run-time performance, and we discussed various ideas for simulation speed-up. This is another nice remark which does not get processed by LaTeX. This is a nice remark which does not get processed by LaTeX. Besides this, while gathering the ⟨replacement text⟩ for \foobar, the phrase \end's catcode is not 14.\\ , you will have all the tokens that form the comment-environment within the ⟨replacement text⟩ of \foobar. comment.\fi or But all those approaches are not foolproof.Į.g., you cannot use them for whatsoever commenting inside macro-arguments or within the ⟨balanced text⟩ of a definition: E.g., the approach of using things like \iffalse. ![]() the approach of using the comment-package. There are approaches which aim at having (La)TeX read and tokenize things and then carry out the resulting tokens in a way where they vanish without yielding visible output.Į.g. That's why usually an empty line/two consecutive line-breaks in the input yield the token \par because at the second of these two linebreaks, (La)TeX will encounter the endline-character of category code 5 while the reading apparatus is in state N.) Usually \endlinechar has the number 13 and 13 is the number of the code point of the return-character in (La)TeX's internal encoding (which either is ASCII or is UTF-8), and the return-character/character 13 has category code 5. Usually (La)TeX does remove space-characters (the space character's code-point has the number 32 both in ASCII and in UTF-8) from line-endings and then does attach a character whose code point's number in (La)TeX's internal encoding (which either is ASCII or is UTF-8) equals the number of the integer-parameter \endlinechar before further processing that line of input. (La)TeX reads input line by line and processes each line character by character. ![]() Afterwards (La)TeX will start tokenizing the next line and thus the reading-apparatus will be in state N. The subtle difference to using a character of category code 14(comment) is: If you use a character of category code 5 (end of line), depending on the state of the reading-apparatus you get (in state N=new line) a \par-token or (in state M=middle of line) a space-token or (in state S=skipping blanks) no token at all for this category-code-5-character. (You can also use characters of category-code 5(end of line) for having (La)TeX cease tokenizing the current line of input. Endline-comments by means of % (or any other character whose category-code at the time of reading and tokenizing the input in question is 14(comment) ) are possible.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |