Lines Matching refs:source
6 * Redistribution and use in source and binary forms, with or without
9 * 1. Redistributions of source code must retain the above copyright
53 // characters in |source| (after collapsing \r\n, etc).
54 ALWAYS_INLINE bool peek(SegmentedString& source)
56 m_nextInputCharacter = source.currentChar();
67 return processNextInputCharacter(source);
70 // Returns whether there are more characters in |source| after advancing.
71 ALWAYS_INLINE bool advance(SegmentedString& source)
73 source.advanceAndUpdateLineNumber();
74 if (source.isEmpty())
76 return peek(source);
88 bool processNextInputCharacter(SegmentedString& source)
91 ASSERT(m_nextInputCharacter == source.currentChar());
95 source.advancePastNewlineAndUpdateLineNumber();
96 if (source.isEmpty())
98 m_nextInputCharacter = source.currentChar();
109 if (m_nextInputCharacter == '\0' && !shouldTreatNullAsEndOfFileMarker(source)) {
111 source.advancePastNonNewline();
112 if (source.isEmpty())
114 m_nextInputCharacter = source.currentChar();
123 bool shouldTreatNullAsEndOfFileMarker(SegmentedString& source) const
125 return source.isClosed() && source.length() == 1;