mirror of
				https://github.com/zsh-users/zsh-syntax-highlighting.git
				synced 2025-10-31 10:04:31 +00:00 
			
		
		
		
	internal: Document the ':regular' state.
This commit is contained in:
		
							parent
							
								
									00de155063
								
							
						
					
					
						commit
						2dbcb575e5
					
				| @ -156,7 +156,7 @@ _zsh_highlight_main_highlighter() | |||||||
|   # - :sudo_arg:   The argument to a sudo leading-dash option that takes one, |   # - :sudo_arg:   The argument to a sudo leading-dash option that takes one, | ||||||
|   #                when given as a separate word; i.e., "foo" in "-u foo" (two |   #                when given as a separate word; i.e., "foo" in "-u foo" (two | ||||||
|   #                words) but not in "-ufoo" (one word). |   #                words) but not in "-ufoo" (one word). | ||||||
|   # - :regular:    "Not a command word". |   # - :regular:    "Not a command word", and command delimiters are permitted. | ||||||
|   #                Mainly used to detect premature termination of commands. |   #                Mainly used to detect premature termination of commands. | ||||||
|   # |   # | ||||||
|   # When the kind of a word is not yet known, $this_word / $next_word may contain |   # When the kind of a word is not yet known, $this_word / $next_word may contain | ||||||
| @ -191,7 +191,10 @@ _zsh_highlight_main_highlighter() | |||||||
|       (( --in_redirection )) |       (( --in_redirection )) | ||||||
|     fi |     fi | ||||||
|     if (( in_redirection == 0 )); then |     if (( in_redirection == 0 )); then | ||||||
|  |       # Initialize $next_word to its default value. | ||||||
|       next_word=':regular:' |       next_word=':regular:' | ||||||
|  |     else | ||||||
|  |       # Stall $next_word. | ||||||
|     fi |     fi | ||||||
|     # $already_added is set to 1 to disable adding an entry to region_highlight |     # $already_added is set to 1 to disable adding an entry to region_highlight | ||||||
|     # for this iteration.  Currently, that is done for "" and $'' strings, |     # for this iteration.  Currently, that is done for "" and $'' strings, | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Daniel Shahaf
						Daniel Shahaf