Skip to content

vrepl: fix variable name starts with print (fix #13981) - #21806

Merged
spytheman merged 1 commit into
vlang:masterfrom
yuyi98:fix_vrepl_variable
Jul 5, 2024
Merged

spytheman merged 1 commit into
vlang:masterfrom
yuyi98:fix_vrepl_variable

Conversation

@yuyi98

@yuyi98 yuyi98 commented Jul 5, 2024

Copy link
Copy Markdown
Member

This PR fix variable name starts with print (fix #13981).

  • Fix variable name starts with print.
  • Add test.
PS D:\Vlang\v> v
 ____    ____
 \   \  /   /  |  Welcome to the V REPL (for help with V itself, type  exit , then run  v help ).
  \   \/   /   |  Note: the REPL is highly experimental. For best V experience, use a text editor,
   \      /    |  save your code in a  main.v  file and execute:  v run main.v
    \    /     |  V 0.4.6 a67bfeb . Use  list  to see the accumulated program so far.
     \__/      |  Use Ctrl-C or  exit  to exit, or  help  to see other available commands.

>>> a_variable := 'yessir'
>>> a_variable
yessir
>>> printme := 'ohno'
>>> printme
ohno
>>> 

@spytheman
spytheman merged commit 35e6a40 into vlang:master Jul 5, 2024
@yuyi98
yuyi98 deleted the fix_vrepl_variable branch July 5, 2024 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

V REPL passes input directly into println, allowing arbitrary script execution

2 participants