Return whether or not the element is a "literal" in the context of a SQL expression construct.
(element: Any)
| 78 | |
| 79 | |
| 80 | def _is_literal(element: Any) -> bool: |
| 81 | """Return whether or not the element is a "literal" in the context |
| 82 | of a SQL expression construct. |
| 83 | |
| 84 | """ |
| 85 | |
| 86 | return not isinstance( |
| 87 | element, |
| 88 | (Visitable, schema.SchemaEventTarget), |
| 89 | ) and not hasattr(element, "__clause_element__") |
| 90 | |
| 91 | |
| 92 | def _deep_is_literal(element): |
no outgoing calls
no test coverage detected