Skip to content

Commit

Permalink
添加sfinae
Browse files Browse the repository at this point in the history
  • Loading branch information
Sekka16 committed Jul 11, 2024
1 parent 52991d9 commit 624fdcd
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
File renamed without changes.
18 changes: 18 additions & 0 deletions source/_posts/language/cpp/sfinae.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
title: C++中的SFINAE
date: 2024-07-11 21:00:00
tags:
categories:
description:
---

# Substitution Failure Is Not An Error

## 模板的特化(非必须)


## SFINAE的基本原理

**核心思想:**当编译器在模板实例化过程中尝试替换模板参数时,如果替换失败,编译器不会报错而是尝试其他可能的重载,只有当所有可能的重载全部都失败时,编译器才会报错。


File renamed without changes.

0 comments on commit 624fdcd

Please sign in to comment.