Super Sampling
Super sampling and anti-aliasing are two different things. Super sampling is just rendering a frame at a higher resolution so that you have more information . This higher-resolution image is then down-sampled. This is especially useful when objects are very thin and might have been missed when sampling on a lower resolution. Down sampling from a higher resolution means they still have some influence. However since you can't super sample in a shader let's move on!
Shader based anti-aliasing
There are actually several techniques for shader based anti-aliasing. You could look up papers and example code of FXAA and MLAA. A nice comparison of quality can be found here. Let me out-line the general idea.
A naive approach to anti-aliasing would just be to gather information from neighboring pixels. While this does get rid of jagged edges somewhat it also blurs important details.
FXAA and MLAA are used in modern graphics pipelines where the normals, depth, and color information is often available separately even during the post-processing step. FXAA and MLAA use the color and depth/and or normal information to compute where edges occur. An edge could be the pixels on the line between the roof of a house and the horizon. These kinds of edges can be blurred to decreased aliasing without losing too much details in textures.