Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
uPython-mirror
Commits
3754c4a0
Commit
3754c4a0
authored
Jan 20, 2014
by
Paul Sokolovsky
Browse files
mp_obj_get_qstr(): Handle MP_OBJ_QSTR.
parent
91d457a2
Changes
1
Hide whitespace changes
Inline
Side-by-side
py/obj.c
View file @
3754c4a0
...
...
@@ -222,7 +222,9 @@ void mp_obj_get_complex(mp_obj_t arg, mp_float_t *real, mp_float_t *imag) {
#endif
qstr
mp_obj_get_qstr
(
mp_obj_t
arg
)
{
if
(
MP_OBJ_IS_TYPE
(
arg
,
&
str_type
))
{
if
(
MP_OBJ_IS_QSTR
(
arg
))
{
return
MP_OBJ_QSTR_VALUE
(
arg
);
}
else
if
(
MP_OBJ_IS_TYPE
(
arg
,
&
str_type
))
{
return
mp_obj_str_get
(
arg
);
}
else
{
assert
(
0
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment