---
source: crates/laburnum-syntax-macro/src/tests/ast_tests.rs
expression: "use laburnum_syntax_macro::tests::ast_tests::test_ast_error_not_struct"
snapshot_kind: text
---
Input: >
  #[laburnum_syntax(AST)]
  pub enum NotAStruct {
      Variant1,
      Variant2,
  }

Error: >
  Error(
      [
          "#[laburnum_syntax] can only be applied to structs",
          "help: This attribute is designed to work with struct definitions only",
          "hint: Try using: #[laburnum_syntax(AST)] pub struct MyStruct { ... }",
      ],
  )
