Skip to content

Diesel cannot infer schema when table has builder column #934

@alanhdu

Description

@alanhdu

When I have a table with a column named builder:

CREATE TABLE diesel_test (
    id INTEGER PRIMARY KEY,
    builder INTEGER
);

then compiling anything with infer_schema! fails with:

$ cargo check
   Compiling scratch v0.1.0 (file:///vagrant/scratch)
error[E0530]: let bindings cannot shadow unit structs
  |
  = note: this error originates in a macro outside of the current crate

error[E0530]: let bindings cannot shadow unit structs
  |
  = note: this error originates in a macro outside of the current crate

error[E0530]: let bindings cannot shadow unit structs
  |
  = note: this error originates in a macro outside of the current crate

error[E0530]: let bindings cannot shadow unit structs
  |
  = note: this error originates in a macro outside of the current crate

error: aborting due to previous error(s)

error: Could not compile `scratch`.

This is with diesel 0.13 and rust 1.17.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions