'main': Don't highlight at the $PS3 prompt.
The input to the $PS3 prompt is not commands, so the 'main' highlighter is not applicable to it. Fixes zsh-users/zsh-syntax-highlighting#268.
This commit is contained in:
		
							parent
							
								
									30d8f92df2
								
							
						
					
					
						commit
						451665cb2a
					
				|  | @ -108,6 +108,15 @@ _zsh_highlight_main_highlighter() | |||
|   emulate -L zsh | ||||
|   setopt localoptions extendedglob bareglobqual | ||||
| 
 | ||||
|   # At the PS3 prompt, highlight nothing. | ||||
|   # | ||||
|   # (We can't check this in _zsh_highlight_main_highlighter_predicate because | ||||
|   # if the predicate returns false, the previous value of region_highlight | ||||
|   # would be reused.) | ||||
|   if [[ $CONTEXT == 'select' ]]; then | ||||
|     return | ||||
|   fi | ||||
| 
 | ||||
|   ## Variable declarations and initializations | ||||
|   local start_pos=0 end_pos highlight_glob=true arg style | ||||
|   local in_array_assignment=false # true between 'a=(' and the matching ')' | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue