Install portaudio using homebrew (or method of your choice)
brew install portaudiocreate $HOME/.pydistutils.cfg using the include and lib directories of your portaudio install:
[build_ext]
| [ | |
| { | |
| "backcolor": "#ffffff", | |
| "name": "Adelheid", | |
| "author": "floookay", | |
| "switchMount": "cherry", | |
| "switchBrand": "gateron", | |
| "pcb": true | |
| }, | |
| [ |
Install portaudio using homebrew (or method of your choice)
brew install portaudiocreate $HOME/.pydistutils.cfg using the include and lib directories of your portaudio install:
[build_ext]
| fn rv(head: Option<~Node>) -> Option<~Node>{ | |
| let mut return_head = None; | |
| let mut current_head = head; | |
| loop { | |
| match current_head.take() { | |
| Some(node) => { | |
| let mut node = node; //make the node usable | |
| current_head = node.next.take(); | |
| node.next = return_head; | |
| return_head = Some(node); |
| fn reverse_linkedlist(head: Option<~Node>) -> Option<~Node> { | |
| let mut result = head; | |
| loop { | |
| match result.next { | |
| Some(~node) => { | |
| let old_next = node.next; | |
| node.next = result; | |
| result = old_next; | |
| }, | |
| None => { |
| struct Node { | |
| value: uint, | |
| /*make sure that the list can terminate*/ | |
| next: Option<~Node> | |
| } | |
| fn main() { | |
| /*define a vector of numbers*/ | |
| let v = [1u,2,3,4]; |