Not sure if this is a bug or not.

Example:
---------------------------------------------------

fun! s:Foo()
endfun

fun! s:Bar()
endfun

let name_foo = get(function('s:Foo'), 'name')
let name_bar = get(funcref('s:Bar'), 'name')

echo printf('"%s" vs "%s"', name_foo, name_bar)

exe "function " . name_foo
exe "function " . name_bar

---------------------------------------------------

Result:
---------------------------------------------------

"<SNR>116_Foo" vs "<80><fd>R116_Bar"
   function <SNR>116_Foo()
   endfunction
   function <SNR>116_Bar()
   endfunction

---------------------------------------------------

When the Funcref is a funcref() instead of function() the
"<SNR>" part is "0x80fd52".

As one can use the the name starting with 0x80 for looking
up by :function, I'm not sure if it is a bug or a feature.

It looks like a signature of sorts and can perhaps be used
to reliably distinguish the two from one another?

Best regards,
M



-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/Oyz0Zhjv22vHkwgPUjeKEFPwC3neZ0sZtVojOldLO9gRSXXVLpVAaQ-OCGf7KG2RRrpP8TX9W_U0Ws6yaTZ4somJcXzNDKphPIrzLgHXBio%3D%40protonmail.com.

Raspunde prin e-mail lui