Skip to content

Instantly share code, notes, and snippets.

@plasma-effect
plasma-effect / main.cpp
Last active August 4, 2017 06:49
お前またparser作る気か
#include"xpeaming.hpp"
#include<iostream>
using namespace xpeaming;
struct ab_t
{
};
struct bc_t
{
@plasma-effect
plasma-effect / parser.hpp
Last active June 30, 2022 02:07
parser定期
// Copyright plasma-effect 2017.
// Distributed under the Boost Software License, Version 1.0.
// See http://www.boost.org/LICENSE_1_0.txt
#pragma once
#include<vector>
#include<optional>
#include<tuple>
#include<utility>
#include<map>
#include<array>
@plasma-effect
plasma-effect / parser.hpp
Created April 12, 2017 16:16
template_parser
// Copyright plasma-effect 2017.
// Distributed under the Boost Software License, Version 1.0.
// (See at http://www.boost.org/LICENSE_1_0.txt)
#pragma once
#include<vector>
#include<optional>
#include<variant>
#include<memory>
#include<string>
//#define _DEBUG
using System;
using System.Collections.Generic;
using System.Linq;
using System.Numerics;
using System.Text;
using System.Threading.Tasks;
namespace RecursiveFunction
{
#pragma once
#include<optional>
#include<variant>
#include<tuple>
#include<string_view>
#include<functional>
#include<array>
#include<set>
namespace single_parse
@plasma-effect
plasma-effect / Main.cpp
Created December 6, 2016 15:17
洗濯機クソコラ生成器
#include<Siv3D.hpp>
#include<algorithm>
typedef std::pair<double, double> point;
typedef point size;
double& x(point& p)
{
return p.first;
}
double& y(point& p)
@plasma-effect
plasma-effect / main.md
Last active December 4, 2016 12:07
VS2017の新機能

辞世の句

PMPやってたらコンパイラ間の挙動の違いに飲み込まれて死んだ。大体msvcが悪い。(自由律)

はじめに

この記事はC++アドベントカレンダー4日目の記事です。
昨日はコンパイル中にコンパイルする「コンパイル時Cコンパイラ」をつくった話でした。

先日VS2017RCが出ました。VC++のコア言語とライブラリに関して新機能をチェックしていこうという記事です。全部は無理ですが。

以下プロパティの言語標準を「ISO C++ 標準の最終草案 (/std:c++latest)」にしていることを前提とします。

@plasma-effect
plasma-effect / main.md
Created November 27, 2016 12:12
light_adt

plasma.ADTにlight_adt.hppを追加した。使い方は以下の通り。

#include<iostream>
#include<string>
#include"light_adt.hpp"

using namespace plasma_adt;
struct list :data_type<list, int, tuple<int, list>>
{
	templatelist(T&amp;&amp; arg) :data_type(std::forward(arg))
@plasma-effect
plasma-effect / main
Created November 15, 2016 14:51
ジャパニーズなかなか迷惑コード(TMPエラトステネス)
#include<iostream>
#include<type_traits>
#include<utility>
#include<functional>
namespace eratosthenes
{
template<std::size_t I, class Sequence>struct add;
template<std::size_t I, std::size_t... Is>struct add<I, std::index_sequence<Is...>>
{
#pragma once
#ifndef PLASMA_REGEXPR_
#define PLASMA_REGEXPR_
#include<string>
#include<array>
#include<vector>
#include<memory>
#include<typeindex>
#include<boost/utility/string_view.hpp>