source: src/libcfa/containers/pair @ eaa5043

aaron-thesisarm-ehcleanup-dtorsdeferred_resndemanglerjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprnew-envno_listpersistent-indexerresolv-newwith_gc
Last change on this file since eaa5043 was eaa5043, checked in by Aaron Moss <a3moss@…>, 5 years ago

Added containers/pair to stdlib (doesn't build yet for some reason)

  • Property mode set to 100644
File size: 1.2 KB
Line 
1//
2// Cforall Version 1.0.0 Copyright (C) 2016 University of Waterloo
3//
4// The contents of this file are covered under the licence agreement in the
5// file "LICENCE" distributed with Cforall.
6//
7// pair --
8//
9// Author           : Aaron Moss
10// Created On       : Wed Apr 12 15:32:00 2017
11// Last Modified By : Aaron Moss
12// Last Modified On : Wed Apr 12 15:32:00 2017
13// Update Count     : 1
14//
15
16#ifndef PAIR_H
17#define PAIR_H
18
19forall(otype R, otype S) struct pair {
20        R first;
21        S second;
22};
23
24forall(otype R, otype S
25        | { int ?==?(R, R); int ?<?(R, R); int ?<?(S, S); })
26int ?<?(pair(R, S) p, pair(R, S) q);
27
28forall(otype R, otype S
29        | { int ?==?(R, R); int ?<?(R, R); int ?<=?(S, S); })
30int ?<=?(pair(R, S) p, pair(R, S) q);
31
32forall(otype R, otype S | { int ?==?(R, R); int ?==?(S, S); })
33int ?==?(pair(R, S) p, pair(R, S) q);
34
35forall(otype R, otype S | { int ?!=?(R, R); int ?!=?(S, S); })
36int ?!=?(pair(R, S) p, pair(R, S) q);
37
38forall(otype R, otype S
39        | { int ?==?(R, R); int ?>?(R, R); int ?>?(S, S); })
40int ?>?(pair(R, S) p, pair(R, S) q);
41
42forall(otype R, otype S
43        | { int ?==?(R, R); int ?>?(R, R); int ?>=?(S, S); })
44int ?>=?(pair(R, S) p, pair(R, S) q);
45
46#endif // PAIR_H
47
48// Local Variables: //
49// mode: c //
50// tab-width: 4 //
51// End: //
Note: See TracBrowser for help on using the repository browser.