Delimiter matching: # inside string not surrounding with #{}

View: New views
3 Messages — Rating Filter:   Alert me  

Delimiter matching: # inside string not surrounding with #{}

by Chris Kutler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello,

Tor wrote to me awhile back that I should document that ....

And if you press “#” inside a string or regular expression, it will surround the text with #{}.

I thought that he meant that if I clicked inside a string (such as "string") and pressed # I would get something like #{"string"}. Instead I get "str#{}ing".

Can someone better explain how to surround text with #{}


Re: Delimiter matching: # inside string not surrounding with #{}

by Anthony Richardson-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

That is the expected behaviour, if you want it to wrap any of the contents of the string you need to select the content and then press #.

On Wed, Oct 15, 2008 at 8:09 AM, Chris Kutler <Chris.Kutler@...> wrote:
Hello,

Tor wrote to me awhile back that I should document that ....

And if you press "#" inside a string or regular expression, it will surround the text with #{}.

I thought that he meant that if I clicked inside a string (such as "string") and pressed # I would get something like #{"string"}. Instead I get "str#{}ing".

Can someone better explain how to surround text with #{}



Re: Delimiter matching: # inside string not surrounding with #{}

by Chris Kutler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks. I wasn't thinking straight. I was selecting "string" instead of string (and /abc/ instead of abc).

Anthony Richardson wrote:
That is the expected behaviour, if you want it to wrap any of the contents of the string you need to select the content and then press #.

On Wed, Oct 15, 2008 at 8:09 AM, Chris Kutler <Chris.Kutler@...> wrote:
Hello,

Tor wrote to me awhile back that I should document that ....

And if you press "#" inside a string or regular expression, it will surround the text with #{}.

I thought that he meant that if I clicked inside a string (such as "string") and pressed # I would get something like #{"string"}. Instead I get "str#{}ing".

Can someone better explain how to surround text with #{}