Skip to content

Instantly share code, notes, and snippets.

device:~/tryrust/build (git)-[master]- clements> /usr/local/bin/rustc /tmp/foo.rs
dyld: lazy symbol binding failed: Symbol not found: __ZN10lang_start20haf38a73a4ecfd9abKoeE
Referenced from: /usr/local/bin/rustc
Expected in: x86_64-apple-darwin/stage1/lib/rustlib/x86_64-apple-darwin/lib/libnative-4e7c5e5c.dylib
dyld: Symbol not found: __ZN10lang_start20haf38a73a4ecfd9abKoeE
Referenced from: /usr/local/bin/rustc
Expected in: x86_64-apple-darwin/stage1/lib/rustlib/x86_64-apple-darwin/lib/libnative-4e7c5e5c.dylib
zsh: trace trap /usr/local/bin/rustc /tmp/foo.rs

Keybase proof

I hereby claim:

  • I am jbclements on github.
  • I am jbclements (https://keybase.io/jbclements) on keybase.
  • I have a public key whose fingerprint is B3A9 99DD 8C82 67AE 9104 368E 8FAB 60E7 084E 8E5F

To claim this, I am signing this object:

@jbclements
jbclements / qsort-with-mutation-original.rkt
Created May 8, 2015 23:53
This version of the file performs an in-place iterative quicksort on a mutable vector.
#lang plai-typed
#;(require rackunit)
(require (typed-in
racket (round : (number -> number))))
;; let's implement quicksort. Using mutation.
@jbclements
jbclements / qsort-store-passing-style.rkt
Created May 8, 2015 23:57
This version of the file also performs an in-place imperative quicksort... but using store-passing style!
#lang plai-typed
#;(require rackunit)
(require (typed-in
racket (round : (number -> number))))
;; let's implement quicksort. Using mutation.
;; a store is a map from numbers to numbers
@jbclements
jbclements / devres.rkt
Created March 28, 2012 17:24
devres.c only better....
(with-handlers
([cant-alloc -> NULL]
[cant-remap -> (devres-free the-box) NULL])
(define the-box (devres-alloc devm-ioremap-release, GFP_KERNEL))
(define remapped (ioremap-prot offset size flags))
(set-box! the-box remapped)
(devres-add dev the-box)
addr)
@jbclements
jbclements / stringlengths.c
Created March 28, 2012 20:32
One way to add string lengths
int numChars(char* word)
{
int i, j, sum = 0;
for(i = 0; word[i][j] != '\0'; i++)
{
for(j = 0; word[i][j] != '\0'; j++)
{
sum++;
}
@jbclements
jbclements / stringlengths.c
Created March 28, 2012 20:33
Another way to add string lengths
int numChars(char * strings[], int len) {
int sum = 0, i;
for (i = 0; i < len; i++) {
sum += strlen(strings[i]);
}
return sum;
}
@jbclements
jbclements / stringlengths.c
Created March 28, 2012 20:34
A third way to add string lengths
int numChars(char * strings[], int len) {
sumOf(lengths(strings));
}
@jbclements
jbclements / part-of-field_routines.f90
Created March 31, 2012 16:16
Extracted random subroutine from CMISS/cm tree
!================================================================================================================================
!
!>Initialises the interpolated point metrics for an interpolated point.
SUBROUTINE FIELD_INTERPOLATED_POINT_METRICS_INITIALISE(INTERPOLATED_POINT,INTERPOLATED_POINT_METRICS,ERR,ERROR,*)
!Argument variables
TYPE(FIELD_INTERPOLATED_POINT_TYPE), POINTER :: INTERPOLATED_POINT !A pointer to the interpolated point to initliase the interpolated point metrics for
TYPE(FIELD_INTERPOLATED_POINT_METRICS_TYPE), POINTER :: INTERPOLATED_POINT_METRICS !<On exit, a pointer to the interpolated point metrics that have been initialised
INTEGER(INTG), INTENT(OUT) :: ERR !<The error code
@jbclements
jbclements / bootstrap-carousel-excerpt.js
Created April 4, 2012 19:11
Excerpt from twitter/bootstrap docs/assets/js