Переглянути джерело

LibJS: Fully qualify the use of AK::is in MUST_OR_THROW_OOM

This is to allow using this macro in contexts that have defined `is`
already. For example, in ObjectConstructor, there is a native function
`is` which would trip up the compiler without this change.
Timothy Flynn 2 роки тому
батько
коміт
109b190a19
1 змінених файлів з 1 додано та 1 видалено
  1. 1 1
      Userland/Libraries/LibJS/Runtime/Completion.h

+ 1 - 1
Userland/Libraries/LibJS/Runtime/Completion.h

@@ -42,7 +42,7 @@ namespace JS {
             /* We can't explicitly check for OOM because InternalError does not store the ErrorType */ \
             /* We can't explicitly check for OOM because InternalError does not store the ErrorType */ \
             VERIFY(_completion.value().has_value());                                                   \
             VERIFY(_completion.value().has_value());                                                   \
             VERIFY(_completion.value()->is_object());                                                  \
             VERIFY(_completion.value()->is_object());                                                  \
-            VERIFY(is<JS::InternalError>(_completion.value()->as_object()));                           \
+            VERIFY(::AK::is<JS::InternalError>(_completion.value()->as_object()));                     \
                                                                                                        \
                                                                                                        \
             return _completion;                                                                        \
             return _completion;                                                                        \
         }                                                                                              \
         }                                                                                              \