dbc

Crates.iodbc
lib.rsdbc
version
sourcesrc
created_at2017-07-09 05:52:25.331331
updated_at2017-07-14 19:26:43.136752
descriptionSimple design by contract assertions
homepagehttps://github.com/lpabon/rust-dbc
repositoryhttps://github.com/lpabon/rust-dbc
max_upload_size
id22714
Cargo.toml error:TOML parse error at line 8, column 1 | 8 | keyworks = ["dbc", "hoare", "assert"] | ^^^^^^^^ unknown field `keyworks`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include`
size0
Luis Pabón (lpabon)

documentation

README

Build Status

rust-dbc

Simple design by contract macros for Rust

Please see the Documentation or example for more information.

Example

Here is a simple require! example:

    let msg = "This is a test";
    let a = 3;
    require!(false, msg, a);

Outputs:

panic: REQUIRE:
file: src/main.rs:45
vars:
msg="This is a test" a=3
thread 'main' panicked at 'assertion failed: false', src/main.rs:45
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
             at /checkout/src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::_print
             at /checkout/src/libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at /checkout/src/libstd/sys_common/backtrace.rs:60
             at /checkout/src/libstd/panicking.rs:355
   3: std::panicking::default_hook
             at /checkout/src/libstd/panicking.rs:371
   4: std::panicking::rust_panic_with_hook
             at /checkout/src/libstd/panicking.rs:549
   5: std::panicking::begin_panic
             at /checkout/src/libstd/panicking.rs:511
   6: example::main
             at ./src/main.rs:45
   7: __rust_maybe_catch_panic
             at /checkout/src/libpanic_unwind/lib.rs:98
   8: std::rt::lang_start
             at /checkout/src/libstd/panicking.rs:433
             at /checkout/src/libstd/panic.rs:361
             at /checkout/src/libstd/rt.rs:57
   9: main
  10: __libc_start_main
  11: _start
Commit count: 21

cargo fmt