Install yasnippet and vala-snippets packages
This commit is contained in:
		| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: class  | ||||||
|  | # key: cla | ||||||
|  | # -- | ||||||
|  | public class ${1:`(file-name-sans-extension (buffer-name))`} : ${2:Glib.Object} { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: constructor | ||||||
|  | # key: con | ||||||
|  | # -- | ||||||
|  | public ${1:`(file-name-sans-extension (buffer-name))`}($2) { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: property | ||||||
|  | # key: prop | ||||||
|  | # -- | ||||||
|  |  | ||||||
|  | public ${1:type} ${2:name} { | ||||||
|  |     get { $3;} | ||||||
|  |     set { $4;} | ||||||
|  | }$0 | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: signal | ||||||
|  | # key: sig | ||||||
|  | # -- | ||||||
|  | public signal ${1:void} ${2:name}(${3:args});$0 | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: simple property - public int var {get; set; default = 0} | ||||||
|  | # key: sprop | ||||||
|  | # -- | ||||||
|  | public ${1:type} ${2:name} { get; set; default = $3; }$0 | ||||||
| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: class main | ||||||
|  | # key: cmain | ||||||
|  | # -- | ||||||
|  | public static int main(string[] args) { | ||||||
|  |     $0 | ||||||
|  |     return 0; | ||||||
|  | } | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: do while loop | ||||||
|  | # key: do | ||||||
|  | # -- | ||||||
|  | do { | ||||||
|  |     $0 | ||||||
|  | } while (${1:condition}); | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: for loop | ||||||
|  | # key: for | ||||||
|  | # -- | ||||||
|  | for (int ${1:i} = 0; $1 < $2; $1++) { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: for each loop | ||||||
|  | # key: foreach | ||||||
|  | # -- | ||||||
|  | foreach (${1:int} ${2:i} in ${3:list}) { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,11 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: if-else if-else statement | ||||||
|  | # key: ifee | ||||||
|  | # -- | ||||||
|  | if (${1:condition}) { | ||||||
|  |     $2 | ||||||
|  | } else if (${3:condition}){ | ||||||
|  |     $4 | ||||||
|  | } else { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: if else statement | ||||||
|  | # key: ife | ||||||
|  | # -- | ||||||
|  | if (${1:condition}) { | ||||||
|  |     $2 | ||||||
|  | } else { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: if statement | ||||||
|  | # key: if | ||||||
|  | # -- | ||||||
|  | if (${1:condition}) { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: switch statement | ||||||
|  | # key: switch | ||||||
|  | # -- | ||||||
|  | switch (${1:condition}) { | ||||||
|  |     case $2: | ||||||
|  |         $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: while statement | ||||||
|  | # key: while | ||||||
|  | # -- | ||||||
|  | while (${1:condition}) { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: enum statement | ||||||
|  | # key: enum | ||||||
|  | # -- | ||||||
|  | enum ${1:name} { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,11 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: try-catch-finally statement | ||||||
|  | # key: tryf | ||||||
|  | # -- | ||||||
|  | try { | ||||||
|  |     $0 | ||||||
|  | } catch (${1:ErrorType} ${2:e}) { | ||||||
|  |  | ||||||
|  | } finally { | ||||||
|  |  | ||||||
|  | } | ||||||
| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: try-catch statement | ||||||
|  | # key: try | ||||||
|  | # -- | ||||||
|  | try { | ||||||
|  |     $0 | ||||||
|  | } catch (${1:ErrorType} ${2:e}) { | ||||||
|  |  | ||||||
|  | } | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: fixme comment | ||||||
|  | # key: f | ||||||
|  | # -- | ||||||
|  | // FIXME: $0 | ||||||
| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: outside main | ||||||
|  | # key: main | ||||||
|  | # -- | ||||||
|  | int main(string[] args){ | ||||||
|  |     $0 | ||||||
|  |     return 0; | ||||||
|  | } | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: new statement | ||||||
|  | # key: new | ||||||
|  | # -- | ||||||
|  | ${1:type} ${2:name} = new $1($3);$0 | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: print string only | ||||||
|  | # key: ps | ||||||
|  | # -- | ||||||
|  | stdout.printf("$1\n");$0 | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: print statement | ||||||
|  | # key: p | ||||||
|  | # -- | ||||||
|  | stdout.printf("$1\n", $2);$0 | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: struct statement | ||||||
|  | # key: struct | ||||||
|  | # -- | ||||||
|  | struct ${1:name} { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: todo comment | ||||||
|  | # key: t | ||||||
|  | # -- | ||||||
|  | // TODO: $0 | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: var statement | ||||||
|  | # key: var | ||||||
|  | # -- | ||||||
|  | var ${1:name} = new $2($3);$0 | ||||||
							
								
								
									
										29
									
								
								elpa/vala-snippets-20150428.2052/vala-snippets-autoloads.el
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								elpa/vala-snippets-20150428.2052/vala-snippets-autoloads.el
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,29 @@ | |||||||
|  | ;;; vala-snippets-autoloads.el --- automatically extracted autoloads | ||||||
|  | ;; | ||||||
|  | ;;; Code: | ||||||
|  | (add-to-list 'load-path (directory-file-name (or (file-name-directory #$) (car load-path)))) | ||||||
|  |  | ||||||
|  | ;;;### (autoloads nil "vala-snippets" "vala-snippets.el" (22535 40606 | ||||||
|  | ;;;;;;  229561 983000)) | ||||||
|  | ;;; Generated autoloads from vala-snippets.el | ||||||
|  |  | ||||||
|  | (autoload 'vala-snippets-initialize "vala-snippets" "\ | ||||||
|  |  | ||||||
|  |  | ||||||
|  | \(fn)" nil nil) | ||||||
|  |  | ||||||
|  | (eval-after-load 'yasnippet '(vala-snippets-initialize)) | ||||||
|  |  | ||||||
|  | ;;;*** | ||||||
|  |  | ||||||
|  | ;;;### (autoloads nil nil ("vala-snippets-pkg.el") (22535 40606 225561 | ||||||
|  | ;;;;;;  987000)) | ||||||
|  |  | ||||||
|  | ;;;*** | ||||||
|  |  | ||||||
|  | ;; Local Variables: | ||||||
|  | ;; version-control: never | ||||||
|  | ;; no-byte-compile: t | ||||||
|  | ;; no-update-autoloads: t | ||||||
|  | ;; End: | ||||||
|  | ;;; vala-snippets-autoloads.el ends here | ||||||
							
								
								
									
										6
									
								
								elpa/vala-snippets-20150428.2052/vala-snippets-pkg.el
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								elpa/vala-snippets-20150428.2052/vala-snippets-pkg.el
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | |||||||
|  | (define-package "vala-snippets" "20150428.2052" "Yasnippets for Vala" | ||||||
|  |   '((yasnippet "0.8.0")) | ||||||
|  |   :url "https://github.com/gopar/vala-snippets") | ||||||
|  | ;; Local Variables: | ||||||
|  | ;; no-byte-compile: t | ||||||
|  | ;; End: | ||||||
							
								
								
									
										31
									
								
								elpa/vala-snippets-20150428.2052/vala-snippets.el
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								elpa/vala-snippets-20150428.2052/vala-snippets.el
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,31 @@ | |||||||
|  | ;;; vala-snippets.el --- Yasnippets for Vala | ||||||
|  |  | ||||||
|  | ;; Copyright (C) 2015 Daniel Gopar | ||||||
|  |  | ||||||
|  | ;; Author: Daniel Gopar | ||||||
|  | ;; URL: https://github.com/gopar/vala-snippets | ||||||
|  | ;; Package-Requires: ((yasnippet "0.8.0")) | ||||||
|  |  | ||||||
|  | ;;; Commentary: | ||||||
|  |  | ||||||
|  | ;;; Code: | ||||||
|  |  | ||||||
|  | (require 'yasnippet) | ||||||
|  |  | ||||||
|  | (defvar vala-snippets-root | ||||||
|  |   (file-name-directory (or load-file-name (buffer-file-name)))) | ||||||
|  |  | ||||||
|  | ;;;###autoload | ||||||
|  | (defun vala-snippets-initialize () | ||||||
|  |   (let ((snip-dir (expand-file-name "snippets" vala-snippets-root))) | ||||||
|  |    (when (boundp 'yas-snippet-dirs) | ||||||
|  |       (add-to-list 'yas-snippet-dirs snip-dir t)) | ||||||
|  |     (yas-load-directory snip-dir))) | ||||||
|  |  | ||||||
|  | ;;;###autoload | ||||||
|  | (eval-after-load 'yasnippet | ||||||
|  |   '(vala-snippets-initialize)) | ||||||
|  |  | ||||||
|  | (provide 'vala-snippets) | ||||||
|  |  | ||||||
|  | ;;; vala-snippets.el ends here | ||||||
							
								
								
									
										1
									
								
								elpa/yasnippet-20160924.2001/snippets/.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								elpa/yasnippet-20160924.2001/snippets/.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | |||||||
|  | **/.yas-compiled-snippets.el | ||||||
							
								
								
									
										1
									
								
								elpa/yasnippet-20160924.2001/snippets/.nosearch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								elpa/yasnippet-20160924.2001/snippets/.nosearch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | |||||||
|  |  | ||||||
							
								
								
									
										4
									
								
								elpa/yasnippet-20160924.2001/snippets/CONTRIBUTORS.txt
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								elpa/yasnippet-20160924.2001/snippets/CONTRIBUTORS.txt
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | |||||||
|  | Please add here your name in alphabetical order (first name) if you contributed with | ||||||
|  |  | ||||||
|  | - Andrea Crotti | ||||||
|  | - James Ferguson | ||||||
							
								
								
									
										18
									
								
								elpa/yasnippet-20160924.2001/snippets/LICENSE
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								elpa/yasnippet-20160924.2001/snippets/LICENSE
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,18 @@ | |||||||
|  | Permission is hereby granted, free of charge, to any person obtaining | ||||||
|  | a copy of this software and associated documentation files (the | ||||||
|  | "Software"), to deal in the Software without restriction, including | ||||||
|  | without limitation the rights to use, copy, modify, merge, publish, | ||||||
|  | distribute, sublicense, and/or sell copies of the Software, and to | ||||||
|  | permit persons to whom the Software is furnished to do so, subject to | ||||||
|  | the following conditions: | ||||||
|  |  | ||||||
|  | The above copyright notice and this permission notice shall be | ||||||
|  | included in all copies or substantial portions of the Software. | ||||||
|  |  | ||||||
|  | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||||||
|  | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||||||
|  | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||||||
|  | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE | ||||||
|  | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION | ||||||
|  | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION | ||||||
|  | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||||||
							
								
								
									
										40
									
								
								elpa/yasnippet-20160924.2001/snippets/README.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										40
									
								
								elpa/yasnippet-20160924.2001/snippets/README.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,40 @@ | |||||||
|  | # Yasnippet official snippet collections | ||||||
|  |  | ||||||
|  | [](https://gitter.im/AndreaCrotti/yasnippet-snippets?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) | ||||||
|  | This repository contains the official snippets for [yasnippet](http://github.com/capitaomorte/yasnippet), as you can see from the git submodules link. | ||||||
|  |  | ||||||
|  | # How to install | ||||||
|  |  | ||||||
|  | There are two options, if you have checked out *yasnippet* already, the only thing you need to do is to run `git submodule update --init` | ||||||
|  | and it will checkout automatically this repository, at the last version it was synchronized too. | ||||||
|  |  | ||||||
|  | Otherwise if you want the latest and greatest snippets collection proceed as follows: | ||||||
|  |  | ||||||
|  | 1. clone this repository | ||||||
|  | 2. add to your .emacs the following | ||||||
|  |    - `(add-to-list 'yas-snippet-dirs "$$DIRECTORY_WHERE_YOU_CLONED")` | ||||||
|  |    - and in case you want to enable yasnippet globally: `(yas-global-mode t)` | ||||||
|  |  | ||||||
|  | 3. `M-x yas-reload-all` to activate them | ||||||
|  |  | ||||||
|  | # Contributing | ||||||
|  |  | ||||||
|  | This repository has now become the default snippets repository (as a submodule) in yasnippet. | ||||||
|  | So if you have any useful snippets for any language or framework please feel free to contribute. | ||||||
|  |  | ||||||
|  | To study the current snippets I suggest to use `M-x yas-describe-tables` | ||||||
|  | which will gave a table representation of all the snippets available in the current mode. | ||||||
|  |  | ||||||
|  |  | ||||||
|  | # Guidelines | ||||||
|  |  | ||||||
|  | Snippets need to be generic enough to be useful for everyone, and not contain anything specific to your own system. | ||||||
|  |  | ||||||
|  | # Various notes | ||||||
|  |  | ||||||
|  | ## HTML snippets | ||||||
|  |  | ||||||
|  | Until September 1st 2014 there were a lot of HTML snippets in the repository, which were sometimes useful but I came to the conclusion that yasnippet was not the right fool for them, so they were removed in this pull request: | ||||||
|  | https://github.com/AndreaCrotti/yasnippet-snippets/pull/49 | ||||||
|  |  | ||||||
|  | To everyone writing a lot of HTML I suggest using [emmet mode](https://github.com/smihica/emmet-mode) instead, which is a much more powerful mode for writing HTML tags. | ||||||
							
								
								
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/antlr-mode/project
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/antlr-mode/project
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: project | ||||||
|  | # key: proj | ||||||
|  | # -- | ||||||
|  | <project name="${1:test}" default="${2:compile}" basedir="${3:.}"> | ||||||
|  |  | ||||||
|  | $0 | ||||||
|  | </project> | ||||||
| @@ -0,0 +1,6 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: property | ||||||
|  | # key: prop | ||||||
|  | # -- | ||||||
|  | <property name="${1:name}" value="${2:value}" /> | ||||||
|  | $0 | ||||||
							
								
								
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/antlr-mode/target
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/antlr-mode/target
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: target | ||||||
|  | # key: target | ||||||
|  | # -- | ||||||
|  | <target name="${1:compile}" ${2:other}> | ||||||
|  |         $0 | ||||||
|  | </target> | ||||||
| @@ -0,0 +1 @@ | |||||||
|  | prog-mode | ||||||
| @@ -0,0 +1 @@ | |||||||
|  | cc-mode | ||||||
							
								
								
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/.yas-setup.el
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/.yas-setup.el
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | |||||||
|  | (defun yas-c++-class-name (str) | ||||||
|  |   "Search for a class name like `DerivedClass' in STR | ||||||
|  | (which may look like `DerivedClass : ParentClass1, ParentClass2, ...') | ||||||
|  |  | ||||||
|  | If found, the class name is returned, otherwise STR is returned" | ||||||
|  |   (yas-substr str "[^: ]*")) | ||||||
|  |  | ||||||
|  | (defun yas-c++-class-method-declare-choice () | ||||||
|  |   "Choose and return the end of a C++11 class method declaration" | ||||||
|  |   (yas-choose-value '(";" " = default;" " = delete;"))) | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/assert
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/assert
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: assert | ||||||
|  | # key: ass | ||||||
|  | # -- | ||||||
|  | assert($0); | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/beginend
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/beginend
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name : v.begin(), v.end() | ||||||
|  | # key: beginend | ||||||
|  | # -- | ||||||
|  | ${1:v}.begin(), $1.end | ||||||
| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: boost_require | ||||||
|  | # key: req | ||||||
|  | # group: boost | ||||||
|  | # -- | ||||||
|  | BOOST_REQUIRE( ${1:condition} ); | ||||||
|  | $0 | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cerr
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cerr
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: cerr | ||||||
|  | # key: err | ||||||
|  | # -- | ||||||
|  | cerr << $0; | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cin
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cin
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: cin | ||||||
|  | # key: cin | ||||||
|  | # -- | ||||||
|  | cin >> $0; | ||||||
							
								
								
									
										11
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/class
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/class
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,11 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: class | ||||||
|  | # key: cls | ||||||
|  | # -- | ||||||
|  | class ${1:Name} | ||||||
|  | { | ||||||
|  | public: | ||||||
|  |     ${1:$(yas/substr yas-text "[^: ]*")}(); | ||||||
|  |     ${2:virtual ~${1:$(yas/substr yas-text "[^: ]*")}();} | ||||||
|  | }; | ||||||
|  | $0 | ||||||
							
								
								
									
										44
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/class11
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										44
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/class11
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,44 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: class11 | ||||||
|  | # key: cls11 | ||||||
|  | # group: c++11 | ||||||
|  | # uuid: d7c41f87-9b8a-479d-bb12-89f4cbdd46a7 | ||||||
|  | # contributor: Ved Vyas | ||||||
|  | # desc: Snippet for C++11 classes based on c++-mode/class. Allows for Rule of | ||||||
|  | # [0, All]. A choice between ";", " = default;", and " = delete;" is presented | ||||||
|  | # for each method. The methods and some of the optional keywords/specifiers are | ||||||
|  | # exposed as fields that users can easily skip-and-clear. | ||||||
|  | # Hackish query-replace-regexp to renumber non-mirror fields in the region | ||||||
|  | # between public and protected (can use N as a field number in the snippet): | ||||||
|  | # \${[0-9N]*:\([^\$]\) -> ${\,(+ 2 \#):\1 | ||||||
|  | # References: | ||||||
|  | # 1. http://en.cppreference.com/w/cpp/language/rule_of_three#Rule_of_five | ||||||
|  | # 2. https://en.wikipedia.org/wiki/Rule_of_three_%28C%2B%2B_programming%29#Example_in_C.2B.2B | ||||||
|  | # 3. http://stackoverflow.com/a/4782927 | ||||||
|  | # -- | ||||||
|  | class ${1:Name} | ||||||
|  | { | ||||||
|  | public: | ||||||
|  | ${2:  ${3://! Default constructor | ||||||
|  |   }${1:$(yas-c++-class-name yas-text)}()${4:;$(yas-c++-class-method-declare-choice)} | ||||||
|  |  | ||||||
|  | }${5:  ${6://! Copy constructor | ||||||
|  |   }${1:$(yas-c++-class-name yas-text)}(const ${1:$(yas-c++-class-name yas-text)} &other)${7:;$(yas-c++-class-method-declare-choice)} | ||||||
|  |  | ||||||
|  | }${8:  ${9://! Move constructor | ||||||
|  |   }${1:$(yas-c++-class-name yas-text)}(${1:$(yas-c++-class-name yas-text)} &&other)${10: noexcept}${11:;$(yas-c++-class-method-declare-choice)} | ||||||
|  |  | ||||||
|  | }${12:  ${13://! Destructor | ||||||
|  |   }${14:virtual }~${1:$(yas-c++-class-name yas-text)}()${15: noexcept}${16:;$(yas-c++-class-method-declare-choice)} | ||||||
|  |  | ||||||
|  | }${17:  ${18://! Copy assignment operator | ||||||
|  |   }${1:$(yas-c++-class-name yas-text)}& operator=(const ${1:$(yas-c++-class-name yas-text)} &other)${19:;$(yas-c++-class-method-declare-choice)} | ||||||
|  |  | ||||||
|  | }${20:  ${21://! Move assignment operator | ||||||
|  |   }${1:$(yas-c++-class-name yas-text)}& operator=(${1:$(yas-c++-class-name yas-text)} &&other)${22: noexcept}${23:;$(yas-c++-class-method-declare-choice)} | ||||||
|  |  | ||||||
|  | }$0 | ||||||
|  |  | ||||||
|  | protected: | ||||||
|  | private: | ||||||
|  | }; | ||||||
							
								
								
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/const_[]
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/const_[]
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: const_[] | ||||||
|  | # key: c[ | ||||||
|  | # -- | ||||||
|  | const ${1:Type}& operator[](${2:int index}) const | ||||||
|  | { | ||||||
|  |         $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: constructor | ||||||
|  | # key: ct | ||||||
|  | # -- | ||||||
|  | ${1:Class}::$1(${2:args}) ${3: : ${4:init}} | ||||||
|  | { | ||||||
|  |         $0 | ||||||
|  | } | ||||||
							
								
								
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cout
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cout
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # contributor: York Zhao <gtdplatform@gmail.com> | ||||||
|  | # name: cout | ||||||
|  | # key: cout | ||||||
|  | # -- | ||||||
|  | `(progn (save-excursion) (goto-char (point-min)) (unless (re-search-forward | ||||||
|  | "^using\\s-+namespace std;" nil 'no-errer) "std::")) | ||||||
|  | `cout << $0${1: << "${2:\n}"}; | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cpp
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cpp
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: cpp | ||||||
|  | # key: cpp | ||||||
|  | # -- | ||||||
|  | #include "`(file-name-nondirectory (file-name-sans-extension (buffer-file-name)))`.h" | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cstd
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/cstd
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: cstd | ||||||
|  | # key: cstd | ||||||
|  | # -- | ||||||
|  | #include <cstdlib> | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/d+=
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/d+=
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: d+= | ||||||
|  | # key: d+= | ||||||
|  | # -- | ||||||
|  | ${1:MyClass}& operator+=(${2:const $1 &}); | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: d_operator<< | ||||||
|  | # key: << | ||||||
|  | # -- | ||||||
|  | friend std::ostream& operator<<(std::ostream&, const ${1:Class}&); | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: d_operator[] | ||||||
|  | # key: [ | ||||||
|  | # -- | ||||||
|  | ${1:Type}& operator[](${2:int index}); | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: d_operator[]_const | ||||||
|  | # key: c[ | ||||||
|  | # -- | ||||||
|  | const ${1:Type}& operator[](${2:int index}) const; | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: d_operator>> | ||||||
|  | # key: >> | ||||||
|  | # -- | ||||||
|  | friend std::istream& operator>>(std::istream&, const ${1:Class}&); | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: d_operator<< | ||||||
|  | # key: << | ||||||
|  | # -- | ||||||
|  | friend std::ostream& operator<<(std::ostream&, const ${1:Class}&); | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/delete
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/delete
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: delete | ||||||
|  | # key: dl | ||||||
|  | # -- | ||||||
|  | delete ${1:pointer}; | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/delete[]
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/delete[]
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: delete[] | ||||||
|  | # key: dla | ||||||
|  | # -- | ||||||
|  | delete[] ${1:arr}; | ||||||
							
								
								
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/doc
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/doc
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: doc | ||||||
|  | # key: doc | ||||||
|  | # -- | ||||||
|  | /** | ||||||
|  |  * $0 | ||||||
|  |  */ | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: dynamic_casting | ||||||
|  | # key: cast | ||||||
|  | # -- | ||||||
|  | check_and_cast<${1:Type} *>(${2:msg}); | ||||||
							
								
								
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/enum
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/enum
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: enum | ||||||
|  | # key: enum | ||||||
|  | # -- | ||||||
|  | enum ${1:NAME}{ | ||||||
|  | $0 | ||||||
|  | }; | ||||||
							
								
								
									
										9
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/fixture
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/fixture
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: fixture | ||||||
|  | # key: fixt | ||||||
|  | # -- | ||||||
|  | BOOST_FIXTURE_TEST_SUITE( ${1:name}, ${2:Fixture} ) | ||||||
|  |  | ||||||
|  | $0 | ||||||
|  |  | ||||||
|  | BOOST_AUTO_TEST_SUITE_END() | ||||||
							
								
								
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/fori
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/fori
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: fori | ||||||
|  | # key: fori | ||||||
|  | # -- | ||||||
|  | for (${1:auto }${2:it} = ${3:var}.begin(); $2 != $3.end(); ++$2) { | ||||||
|  |     $0 | ||||||
|  | } | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/friend
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/friend
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: friend | ||||||
|  | # key: fr | ||||||
|  | # -- | ||||||
|  | friend $0; | ||||||
| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: fun_declaration | ||||||
|  | # key: f | ||||||
|  | # -- | ||||||
|  | ${1:type} ${2:name}(${3:args})${4: const}; | ||||||
							
								
								
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/function
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/function
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: function | ||||||
|  | # key: f | ||||||
|  | # -- | ||||||
|  | ${1:type} ${2:Class}::${3:name}(${4:args})${5: const} | ||||||
|  | { | ||||||
|  |         $0 | ||||||
|  | } | ||||||
							
								
								
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/gtest
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/gtest
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: gtest | ||||||
|  | # key: gtest | ||||||
|  | # group: testing | ||||||
|  | # -- | ||||||
|  | #include <gtest/gtest.h> | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/ignore
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/ignore
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: ignore | ||||||
|  | # key: ignore | ||||||
|  | # -- | ||||||
|  | ${1:std::}cin.ignore(std::numeric_limits<std::streamsize>::max(), '\n'); | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/inline
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/inline
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: inline | ||||||
|  | # key: il | ||||||
|  | # -- | ||||||
|  | inline $0 | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/io
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/io
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: io | ||||||
|  | # key: io | ||||||
|  | # -- | ||||||
|  | #include <iostream> | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/iterator
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/iterator
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: iterator | ||||||
|  | # key: iter | ||||||
|  | # -- | ||||||
|  | ${1:std::}${2:vector<int>}::iterator ${3:iter}; | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/map
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/map
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: map | ||||||
|  | # key: map | ||||||
|  | # -- | ||||||
|  | std::map<${1:type1}$0> ${2:var}; | ||||||
							
								
								
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/module
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/module
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: module | ||||||
|  | # key: mod | ||||||
|  | # -- | ||||||
|  | class ${1:Class} : public cSimpleModule | ||||||
|  | { | ||||||
|  |    $0 | ||||||
|  | } | ||||||
							
								
								
									
										9
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/namespace
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/namespace
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: namespace | ||||||
|  | # key: ns | ||||||
|  | # -- | ||||||
|  | namespace ${1:Namespace} { | ||||||
|  |  | ||||||
|  |           `yas/selected-text` | ||||||
|  |  | ||||||
|  | }  // $1 | ||||||
							
								
								
									
										4
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/ns
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/ns
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | |||||||
|  | #name : namespace ... | ||||||
|  | # key: ns | ||||||
|  | # -- | ||||||
|  | namespace  | ||||||
| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator!= | ||||||
|  | # key: != | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | bool ${1:MyClass}::operator!=(const $1 &other) const | ||||||
|  | { | ||||||
|  |     return !(*this == other); | ||||||
|  | } | ||||||
							
								
								
									
										11
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/operator+
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/operator+
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,11 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator+ | ||||||
|  | # key: + | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | ${1:MyClass} $1::operator+(const $1 &other) | ||||||
|  | { | ||||||
|  |     $1 result = *this; | ||||||
|  |     result += other; | ||||||
|  |     return result; | ||||||
|  | } | ||||||
							
								
								
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/operator+=
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/operator+=
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator+= | ||||||
|  | # key: += | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | ${1:MyClass}& $1::operator+=(${2:const $1 &rhs}) | ||||||
|  | { | ||||||
|  |   $0 | ||||||
|  |   return *this; | ||||||
|  | } | ||||||
							
								
								
									
										14
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/operator=
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/operator=
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,14 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator= | ||||||
|  | # key: = | ||||||
|  | # where this is a reference to myself | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | ${1:MyClass}& $1::operator=(const $1 &rhs) | ||||||
|  | { | ||||||
|  |     // Check for self-assignment! | ||||||
|  |     if (this == &rhs) | ||||||
|  |       return *this; | ||||||
|  |     $0 | ||||||
|  |     return *this; | ||||||
|  | } | ||||||
| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator== | ||||||
|  | # key: == | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | bool ${1:MyClass}::operator==(const $1 &other) const | ||||||
|  | { | ||||||
|  |      $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator[] | ||||||
|  | # key: [] | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | ${1:Type}& operator[](${2:int index}) | ||||||
|  | { | ||||||
|  |         $0 | ||||||
|  | } | ||||||
| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator>> | ||||||
|  | # key: >> | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | std::istream& operator>>(std::istream& is, const ${1:Class}& ${2:c}) | ||||||
|  | { | ||||||
|  |          $0 | ||||||
|  | 	 return is; | ||||||
|  | } | ||||||
| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: operator<< | ||||||
|  | # key: << | ||||||
|  | # group: operator overloading | ||||||
|  | # -- | ||||||
|  | std::ostream& operator<<(std::ostream& os, const ${1:Class}& ${2:c}) | ||||||
|  | { | ||||||
|  |          $0 | ||||||
|  |          return os; | ||||||
|  | } | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/ostream
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/ostream
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: ostream | ||||||
|  | # key: os | ||||||
|  | # -- | ||||||
|  | #include <ostream> | ||||||
							
								
								
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/pack
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/pack
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: pack | ||||||
|  | # key: pack | ||||||
|  | # -- | ||||||
|  | void cNetCommBuffer::pack(${1:type}) | ||||||
|  | { | ||||||
|  |  | ||||||
|  | } | ||||||
|  |  | ||||||
|  | $0 | ||||||
							
								
								
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/private
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/private
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: private | ||||||
|  | # key: pr | ||||||
|  | # -- | ||||||
|  | private: | ||||||
|  |         $0 | ||||||
							
								
								
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/protected
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/protected
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: protected | ||||||
|  | # key: pt | ||||||
|  | # -- | ||||||
|  | protected: | ||||||
|  |         $0 | ||||||
							
								
								
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/public
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/public
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: public | ||||||
|  | # key: pb | ||||||
|  | # -- | ||||||
|  | public: | ||||||
|  |         $0 | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/sstream
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/sstream
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: <sstream> | ||||||
|  | # key: ss | ||||||
|  | # -- | ||||||
|  | #include <sstream> | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/std
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/std
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: std | ||||||
|  | # key: std | ||||||
|  | # -- | ||||||
|  | using namespace std; | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/std_colon
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/std_colon
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: std:: | ||||||
|  | # key: st | ||||||
|  | # -- | ||||||
|  | std::$0 | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/str
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/str
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: str | ||||||
|  | # key: str | ||||||
|  | # -- | ||||||
|  | #include <string> | ||||||
							
								
								
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/template
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/template
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: template | ||||||
|  | # key: temp | ||||||
|  | # -- | ||||||
|  | template<${1:$$(yas/choose-value '("typename" "class"))} ${2:T}> | ||||||
|  | $0 | ||||||
							
								
								
									
										9
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/test case
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/test case
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: test case | ||||||
|  | # key: tc | ||||||
|  | # group: testing | ||||||
|  | # -- | ||||||
|  | BOOST_AUTO_TEST_CASE( ${1:test_case} ) | ||||||
|  | { | ||||||
|  |         $0 | ||||||
|  | } | ||||||
							
								
								
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/test_main
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/test_main
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: test_main | ||||||
|  | # key: test_main | ||||||
|  | # group: testing | ||||||
|  | # -- | ||||||
|  | int main(int argc, char **argv) | ||||||
|  | { | ||||||
|  |       ::testing::InitGoogleTest(&argc, argv); | ||||||
|  |        return RUN_ALL_TESTS(); | ||||||
|  | } | ||||||
							
								
								
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/test_suite
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/test_suite
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: test_suite | ||||||
|  | # key: ts | ||||||
|  | # group: testing | ||||||
|  | # -- | ||||||
|  | BOOST_AUTO_TEST_SUITE( ${1:test_suite1} ) | ||||||
|  |  | ||||||
|  | $0 | ||||||
|  |  | ||||||
|  | BOOST_AUTO_TEST_SUITE_END() | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/this
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/this
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: this | ||||||
|  | # key: th | ||||||
|  | # -- | ||||||
|  | this | ||||||
							
								
								
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/throw
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/throw
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: throw | ||||||
|  | # key: throw | ||||||
|  | # -- | ||||||
|  | throw ${1:MyError}($0); | ||||||
							
								
								
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/try
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								elpa/yasnippet-20160924.2001/snippets/c++-mode/try
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | |||||||
|  | # -*- mode: snippet -*- | ||||||
|  | # name: try | ||||||
|  | # key: try | ||||||
|  | # a bit too intrusive now still, not always I want to do this | ||||||
|  | # -- | ||||||
|  | try { | ||||||
|  |     $0 | ||||||
|  | } catch (${1:type}) { | ||||||
|  |  | ||||||
|  | } | ||||||
Some files were not shown because too many files have changed in this diff Show More
		Reference in New Issue
	
	Block a user